1. Field of the Invention
The present invention relates to an image processing apparatus, method and computer program product, and in particular, relates to a corresponding point detection technique for detecting points (corresponding points) whose features match between a plurality of images.
2. Description of the Related Art
As the technique for detecting corresponding points whose features match between a plurality of images, various methods including KLT method (Tomasi & Kanade, 1991, Detection and Tracking of Point Features) are proposed.
More specifically, as shown in FIGS. 12A and 12B, the method includes a step of inputting two images and extracting a feature point (pixel) from an image (reference image shown in FIG. 12A) to be a reference, and a step of tracking where the feature point is located in the other image (tracking image shown in FIG. 12B) and detecting a point corresponding to the feature point. Here, the point determined as a result of tracking the feature point is referred to as a tracking point. The feature point and tracking point are collectively referred to as corresponding points.
A line segment joining the feature point and the tracking point is referred to as an optical flow (=motion vector) (see FIG. 12B).
There are various methods for tracking a feature point. One of the methods is a gradient method, notably the Lucas-Kanade method. The gradient method acquires a displacement (=motion) between the feature point and the tracking point from gradients (first derivative) of an image signal along the time direction and the space directions.
In general, an advantage of the gradient method is that the processing time is relatively short. On the other hand, a drawback is that the gradient method cannot respond to a large motion. In order to remedy the drawback, a hierarchical gradient method, which individually reduces the two images in stepwise fashion to generate two pyramid hierarchical groups of images and detects a corresponding point by using the hierarchical images as shown in FIG. 13, is proposed (Japanese Patent Application Laid-Open No. 05-61975).
In other words, the hierarchical gradient method tracks the feature point in a low resolution level and then, using the tracking result as an initial value, tracks the point in higher level.